<template>
	<page-body>
		<view class="page">
			<view class="flex align-stretch benben-position-layout flex addNotes_flex_0"
				:style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }">
				<view class='flex align-center justify-between flex-sub addNotes_fd0_0'>
					<view class='flex align-center addNotes_fd0_0_c0' @tap.stop="handleJumpDiy" data-type="back"
						data-url="1">
						<text class='fu-iconfont2  addNotes_fd0_0_c0_c0'>&#xE794;</text>
					</view>
					<text class='addNotes_fd0_0_c1'>添加备注</text>
					<view class='flex align-center addNotes_fd0_0_c0'>
					</view>
				</view>

			</view>
			<view :style="{height: (88+StatusBarRpx)+'rpx'}"></view>
			<!---flex布局flex布局开始-->
			<view class="flex flex-direction flex-wrap align-stretch benben-flex-layout addNotes_flex_1">
				<view class='flex flex-wrap addNotes_fd1_0'>
					<textarea class='flex addNotes_input_fd1_0' :placeholder="type ? '请输入备注' : '输入物品信息或寄送要求，请勿急送违禁品，如有取货码请在骑手接单后再沟通'" :adjust-position='true'
						:maxlength="200" :show-num='true' placeholder-style="color:#999;font-size:28rpx"
						v-model="fd1_0" />
					<!-- <template>
						<view class='flex flex justify-end addNotes_numberfd1_0_c0'>
							<text class='addNotes_numberfd1_0_c0_c0'>{{fd1_0.length}}</text>
							<text class='addNotes_numberfd1_0_c0_c1'>/</text>
							<text class='addNotes_numberfd1_0_c0_c1'>50</text>
						</view>
					</template> -->
				</view>
			</view>

			<!---flex布局flex布局结束-->
			<!---flex布局flex布局开始-->
			<view class="flex flex-direction flex-wrap align-stretch benben-flex-layout" v-if="type">
				<text class='addNotes_fd2_0'>快捷标签</text>
				<benben-select-diy ref="showSelectPopup1715739498448" class-name='flex flex-wrap align-center flex addNotes_fd2_1' 
				:items.sync="labelType" v-model="label_id" :label.sync="label_name" default-type="label_name" default-label="label_name" :allow-cancel='true' 
				type="checkbox" :disabled='false'>
					<template v-for='(item,key0) in labelType'>
						<view v-if="item.isSelected" class='flex align-center flex addNotes_fd2_1_c0' :key="key0" @tap="$refs.showSelectPopup1715739498448.tapHandle(key0)">
							<text class='addNotes_fd2_1_c0_c0'>{{item.label_name}}</text>
						</view>
						<view v-else class='flex align-center flex addNotes_fd2_1_c1' :key="key0" @tap="$refs.showSelectPopup1715739498448.tapHandle(key0)">
							<text class='addNotes_fd2_1_c1_c0'>{{item.label_name}}</text>
						</view>
					</template>
				</benben-select-diy>
			</view>

			<!---flex布局flex布局结束-->
			<view class="flex flex-wrap align-start justify-center benben-position-layout flex addNotes_flex_3" @tap.stop="queding">
				<button class='addNotes_fd3_0'>完成</button>

			</view>
			<view :style="{height: '120rpx'}"></view>


		</view>
	</page-body>
</template>
<script>
	export default {
		components: {},


		data() {
			return {
				"fd1_0": "",
				"labelType": [],
				"label_id": "",
				label_name:'',
				type:'',
				name:''
			};
		},
		computed: {

		},
		watch: {},
		onLoad(options) {
			if(options.type){
				this.type = options.type
			}
			if(options.name1){
				this.fd1_0 = options.name1
			}
			if(options.name2){
				this.name = options.name2
			}
			this.post6683dbabee045()
		},
		onUnload() {

		},
		onReady() {

		},
		onShow() {

		},
		onHide() {

		},
		onResize() {

		},
		onPullDownRefresh() {

		},
		onReachBottom(e) {

		},
		onPageScroll(e) {

		},
		methods: {
			// 购物车
			async post6683dbabee045(){
				let res = await this.$api.get(global.apiUrls.post6683dbabee045);
				
				if (res.data.code != 1) {
				    this.$message.info(res.data.msg);
				    return
				}
				this.labelType = res.data.data
				if(this.name){
					this.label_name = this.name
					this.label_id = this.name
				}
			},
			queding(){
				// console.log(this.label_name,123)
				// return
				let pages = getCurrentPages(); // 当前页页⾯实例
				let nowPage = pages[pages.length -1]; //当前页⾯实例
				let prevPage = pages[pages.length -2]; // 上一页面实例
				prevPage.$vm.prevDateFun(this.fd1_0,this.label_name) // 调用上一页 定义的方法
				// 返回 上一页
				uni.navigateBack({
				  delta:1 // 可以不写，默认值为 1
				})
			},
		}
	};
</script>
<style lang="scss" scoped>
	.page {
		width: 100vw;
		overflow-x: hidden;
		min-height: calc(100vh - var(--window-bottom));
		background: #fff;
		background-size: 100% auto;
	}

	.addNotes_flex_0 {
		background: #fff;
		width: 750rpx;
		height: 88rpx;
		overflow: hidden;
		z-index: 10;
		top: 0rpx;
		background-size: 100% auto !important;
	}

	.addNotes_fd0_0_c1 {
		font-size: 36rpx;
		font-weight: 500;
		color: var(--benbenFontColor0);
	}

	.addNotes_fd0_0_c0_c0 {
		font-size: 32rpx;
		font-weight: 500;
		color: #333;
	}

	.addNotes_fd0_0_c0 {
		width: 180rpx;
		height: 88rpx;
	}

	.addNotes_fd0_0 {
		padding: 0rpx 32rpx 0rpx 32rpx;
		height: 88rpx;
	}

	.addNotes_flex_1 {
		margin: 32rpx 0rpx 32rpx 0rpx;
		padding: 0rpx 32rpx 0rpx 32rpx;
	}

	.addNotes_numberfd1_0_c0_c1 {
		color: #999999;
		font-size: 28rpx;
		font-weight: 500;
		line-height: 40rpx;
	}

	.addNotes_numberfd1_0_c0_c0 {
		color: #999999;
		font-size: 28rpx;
		font-weight: 500;
		line-height: 40rpx;
		text-align: right;
		font-style: normal;
	}

	.addNotes_numberfd1_0_c0 {
		width: 100%;
		font-size: 24rpx;
		color: #FFFFFF;
		line-height: 46rpx;
		font-weight: 400;
	}

	.addNotes_input_fd1_0 {
		width: 100%;
		height: 200rpx;
		font-size: 28rpx;
		font-weight: 400;
		color: #333;
		white-space: pre-wrap;
	}

	.addNotes_fd1_0 {
		background: rgba(246, 247, 249, 1);
		border-radius: 10rpx 10rpx 10rpx 10rpx;
		padding: 24rpx 24rpx 24rpx 24rpx;
	}

	.addNotes_fd2_1_c1_c0 {
		color: var(--benbenFontColor0);
		font-size: 28rpx;
		font-weight: 500;
		line-height: 40rpx;
	}

	.addNotes_fd2_1_c1 {
		border: 1px solid rgba(238, 238, 238, 1);
		margin: 0rpx 14rpx 24rpx 14rpx;
		padding: 0rpx 33rpx 0rpx 33rpx;
		height: 72rpx;
		border-radius: 8rpx;
	}

	.addNotes_fd2_1_c0_c0 {
		color: var(--benbenFontColor3);
		font-size: 28rpx;
		font-weight: 500;
		line-height: 40rpx;
	}

	.addNotes_fd2_1_c0 {
		background: var(--benbenbgColor0);
		padding: 0rpx 33rpx 0rpx 33rpx;
		height: 72rpx;
		border-radius: 8rpx;
		margin: 0rpx 14rpx 24rpx 14rpx;
		background-size: 100% auto;
	}

	::v-deep .addNotes_fd2_1 {
		padding: 0rpx 13rpx 0rpx 13rpx;
	}

	.addNotes_fd2_0 {
		color: #999999;
		font-size: 32rpx;
		font-weight: 500;
		line-height: 45rpx;
		margin: 0rpx 32rpx 32rpx 32rpx;
	}

	.addNotes_flex_3 {
		width: 750rpx;
		height: 120rpx;
		overflow: hidden;
		z-index: 10;
		bottom: calc(0rpx + var(--window-bottom));
	}

	.addNotes_fd3_0 {
		background: var(--benbenbgColor0);
		border-radius: 40rpx 40rpx 40rpx 40rpx;
		width: 654rpx;
		line-height: 80rpx;
		font-size: 28rpx;
		color: #fff;
		height: 80rpx;
	}
</style>
